<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="./js/vue.min.js"></script>
</head>

<body>
    <div id="app">
        <ul>
            <li v-for="(city,index) in arr">
                {{index}}城市：{{city}}
            </li>
        </ul>

        <h2 v-for="(p) in persons">
            {{p.name}}:{{p.age}}
        </h2>
    </div>

</body>
<script>
    var VM = new Vue({
        el: '#app',
        data: {
            arr: [
                "上海",
                "广州",
                "北京",
                "深圳"
            ],
            persons: [{
                name: 'Mary',
                age: 18
            }, {
                name: 'Bob',
                age: 22
            }, {
                name: 'Jane',
                age: 30
            }]
        }
    })
</script>

</html>